package com.github.gin.springboot;

import com.alibaba.fastjson.JSON;
import com.github.gin.springboot.model.City;
import com.github.gin.springboot.respostory.CityRespostory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.support.SpringBootServletInitializer;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.data.domain.Pageable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.persistence.EntityManager;
import javax.transaction.Transactional;

/**
 * Created by FSTMP on 2016/12/16.
 */
@SpringBootApplication
@RestController
@EnableCaching
public class Application /*extends SpringBootServletInitializer*/ {

    @RequestMapping("/login")
    public String test(){
        return "login";
    }

    /*@Override
    protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
        return builder.sources(Application.class);
    }*/

    public static void main(String[] args){
        SpringApplication.run(Application.class,args);
    }
}
